<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>循环输入五门课程的成绩.并计算平均分</title>
	<script>
		var sum=0;
		for(var i=1;i<=5;i++)
		{var s=Number(prompt('第'+i+'门课的成绩'));
         sum+=s;}

        var avg=sum/5;
        console.log(avg)

	</script>
</head>
<body>
	
</body>
</html>